
#ifndef WISHMASTER_CODINGMANAGER_H
#define WISHMASTER_CODINGMANAGER_H

#include <QByteArray>
#include "coder.h"
#include "components/post.h"
#include "singleton.h"
#include "misc.h"

namespace Wishmaster
{
	class WISHMASTER_EXPORT CodingManager : public Singleton<CodingManager>
	{
	public:
		CodingManager();
		virtual ~CodingManager();

		QByteArray store(const QList<ExtraInfo>& extras);
		bool restore(PostPtr& post, const QByteArray& data);

	protected:
		CoderPtr coderByToken(int token);

	private:
		QList<CoderPtr> m_coders;
	};
}

#endif

